﻿<Window x:Class="test3d.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="MeshDiagram3D" Height="600" Width="600" xmlns:my="clr-namespace:MeshDiagram3D">
    <Grid>
        <DockPanel
     Width="Auto"
     VerticalAlignment="Stretch"
     Height="Auto"
     HorizontalAlignment="Stretch"
     Grid.ColumnSpan="1"
     Grid.Column="0"
     Grid.Row="0"
     Margin="0,0,0,0"
     Grid.RowSpan="1">
            <StackPanel>
                <StackPanel.Background>
                    <LinearGradientBrush>
                        <GradientStop Color="Blue" Offset="0"/>
                        <GradientStop Color="LightBlue" Offset=".25"/>
                        <GradientStop Color="White" Offset=".5"/>
                        <GradientStop Color="LightBlue" Offset=".75"/>
                        <GradientStop Color="Blue" Offset="1"/>
                    </LinearGradientBrush>
                </StackPanel.Background>
                <StackPanel Margin="10">
                    <Separator></Separator>
                    <Button Name="btn_Rotator" ClickMode="Press">Rotation</Button>
                    <TextBlock>Zoom:</TextBlock>
                    <TextBox Name="txt_zoom" >1</TextBox>
                    <TextBlock>Rot X:</TextBlock>
                    <TextBox Name="txt_rot_x" >10</TextBox>
                    <TextBlock>Rot Y:</TextBlock>
                    <TextBox Name="txt_rot_y" >10</TextBox>
                    <TextBlock>Rot Z:</TextBlock>
                    <TextBox Name="txt_rot_z" >10</TextBox>
                    <Separator></Separator>

                    <Button Name="btn_CameraLocation" ClickMode="Press">Cam. Location</Button>
                    <TextBlock>Distance:</TextBlock>
                    <TextBox Name="txt_camloc_zoom" >1</TextBox>
                    <TextBlock>Loc X:</TextBlock>
                    <TextBox Name="txt_camloc_x" >10</TextBox>
                    <TextBlock>Loc Y:</TextBlock>
                    <TextBox Name="txt_camloc_y" >10</TextBox>
                    <TextBlock>Loc Z:</TextBlock>
                    <TextBox Name="txt_camloc_z" >10</TextBox>
                    <Separator></Separator>
                    <TextBlock>Visibility:</TextBlock>
                    <CheckBox Name="CheckBoxTriangles"  IsChecked="True">Triangles</CheckBox>
                    <CheckBox Name="CheckBoxLines" IsChecked="True">Lines</CheckBox>
                    <CheckBox Name="CheckBoxTexts3D"  IsChecked="False">Labels 3D</CheckBox>
                    <CheckBox Name="CheckBoxTexts2D" IsChecked="True">Labels 2D</CheckBox>
                    <Separator></Separator>
                </StackPanel>
            </StackPanel>
            <DockPanel>
                <TextBlock Name="slider_zoom_textblock" 
                           HorizontalAlignment="Center" VerticalAlignment="Center" 
                           RenderTransformOrigin="0.5,0.5" Height="Auto" Width="8" TextWrapping="Wrap" Margin="4">Zoom/Distance
                    <!--<TextBlock.RenderTransform>                
    <RotateTransform Angle="-90"/>
  </TextBlock.RenderTransform>-->
                </TextBlock>
                <Slider Name="slider_zoom"
        Orientation="Vertical"
        Minimum="0.1"
        Maximum="20"
        
                        Value="1"
                        DockPanel.Dock="Left"/>
                <TextBlock Name="slider_x_textblock" 
                           HorizontalAlignment="Center" VerticalAlignment="Center" 
                           DockPanel.Dock="Right"
                           RenderTransformOrigin="0.5,0.5" Height="Auto" 
                           Width="8" TextWrapping="Wrap" Margin="4">X</TextBlock>
                <Slider Name="slider_x"
        DockPanel.Dock="Right"
        Orientation="Vertical"
        Minimum="-180"
        Maximum="180"
       />
                <TextBlock Name="slider_z_textblock" 
                           HorizontalAlignment="Center" VerticalAlignment="Center" 
                           DockPanel.Dock="Top"
                           RenderTransformOrigin="0.5,0.5" Height="Auto" 
                           Width="Auto" TextWrapping="Wrap" Margin="4">Z</TextBlock>
                <Slider Name="slider_z"
        DockPanel.Dock="Top"
        Orientation="Horizontal"
        Minimum="-180"
        Maximum="180"
         />
                <TextBlock Name="slider_y_textblock" 
                           HorizontalAlignment="Center" VerticalAlignment="Center" 
                           DockPanel.Dock="Bottom"
                           RenderTransformOrigin="0.5,0.5" Height="Auto" 
                           Width="Auto" TextWrapping="Wrap" Margin="4">Y</TextBlock>
                <Slider Name="slider_y"
        DockPanel.Dock="Bottom"
        Orientation="Horizontal"
        Minimum="-180"
        Maximum="180"
         />
                <Grid ClipToBounds="True">
                    <my:MeshDiagramViewport3D x:Name="MyMeshDiagramViewport3D">
                    </my:MeshDiagramViewport3D>
                    <DockPanel     Width="Auto"      VerticalAlignment="Stretch"      Height="Auto"      HorizontalAlignment="Stretch" >
                        <TextBlock Name="textblock_info" 
                           HorizontalAlignment="Right" VerticalAlignment="Bottom" 
                           DockPanel.Dock="Bottom"
                           RenderTransformOrigin="0.5,0.5" Height="100" 
                           Width="200"  TextWrapping="Wrap" Margin="4" TextAlignment="Right">This is an information</TextBlock>
                    </DockPanel>
                </Grid>
            </DockPanel>

        </DockPanel>
    </Grid>
</Window>
